package com.sos.core.game.events
{
	import com.sos.core.game.Game;
	import com.sos.core.game.GameStatus;
	
	public class GameStatusChangedEvent extends GameEvent
	{
		
		// -------------------------------------------------------------------------------
		// FIELDS
		// -------------------------------------------------------------------------------
		
		private var _oldStatus:GameStatus;
		private var _newStatus:GameStatus;
		
		// -------------------------------------------------------------------------------
		// CONSTRUCTOR
		// -------------------------------------------------------------------------------
		
		/**
		 * Creates a new GameStatusChangedEvent
		 * @param g Game that dispatch the event
		 * @param oldStatus Current status of the game
		 * @param newStatus New status of the game
		 */		
		public function GameStatusChangedEvent(g:Game, oldStatus:GameStatus, newStatus:GameStatus)
		{
			super(GameEvent.EVENT_GAME_STATUS_CHANGED, g);
			// Init
			_oldStatus = oldStatus;
			_newStatus = newStatus;
		}
		
		// -------------------------------------------------------------------------------
		// PROPERTIES
		// -------------------------------------------------------------------------------
		
		public function get oldStatus():GameStatus
		{
			return _oldStatus;
		}

		public function get newStatus():GameStatus
		{
			return _newStatus;
		}


	}
}